package com.vizhuo.client.business.match.goods.url;

import com.vizhuo.client.base.AbstractUrls;
import com.vizhuo.client.business.appmanage.constant.AppVersionConstant;
import com.vizhuo.client.business.match.goods.constant.FindGoodsConstant;
import com.vizhuo.client.business.match.goods.request.AddGoodsRequest;
import com.vizhuo.client.business.match.goods.request.AddRobRequest;
import com.vizhuo.client.business.match.goods.request.AgainPushGoodsRequest;
import com.vizhuo.client.business.match.goods.request.AssignedRunRequest;
import com.vizhuo.client.business.match.goods.request.CancelOrderRequest;
import com.vizhuo.client.business.match.goods.request.FindBoundsCarsRequest;
import com.vizhuo.client.business.match.goods.request.FindBoundsGoodsRequest;
import com.vizhuo.client.business.match.goods.request.FindCarsRequest;
import com.vizhuo.client.business.match.goods.request.FindDayGoodspushRequest;
import com.vizhuo.client.business.match.goods.request.FindGoodsRequest;
import com.vizhuo.client.business.match.goods.request.FindHistoryAddrRequest;
import com.vizhuo.client.business.match.goods.request.FindMyGoodsRequest;
import com.vizhuo.client.business.match.goods.vo.BoundsVo;
import com.vizhuo.client.business.match.goods.vo.GoodsVo;

/**
 * @ClassName: GoodsUrls
 * @Description: 订单管理-我要用车
 * @author TANDP
 * @date 2015-7-9 下午1:56:12
 * 
 */
public class NeedCarUrls extends AbstractUrls {
    /**
     * 发布用车信息/货源信息
     */
    public static final String ADD_GOODS = "/mobile/needCar/addGoods.do";

    /**
     * 待运货源
     */
    public static final String FIND_GOODS = "/mobile/needCar/findGoods.do";

    /**
     * 历史地址记录
     */
    public static final String FIND_HISTORY_ADDR = "/mobile/needCar/findHistoryAddr.do";

    /**
     * 抢单/预约
     */
    public static final String ADD_ROB = "/mobile/needCar/addRob.do";

    /**
     * 待抢单
     */
    public static final String FIND_GOODS_01 = "/mobile/needCar/findGoods01.do";

    /**
     * 要车详情
     */
    public static final String FIND_GOODS_DESC = "/mobile/needCar/findGoodsDesc.do";

    /**
     * 待确认
     */
    public static final String FIND_GOODS_02 = "/mobile/needCar/findGoods02.do";

    /**
     * 抢单详情
     */
    public static final String FIND_ROB_DESC = "/mobile/needCar/findRobDesc.do";

    /**
     * 待评价
     */
    public static final String FIND_GOODS_03 = "/mobile/needCar/findGoods03.do";

    /**
     * 历史
     */
    public static final String FIND_GOODS_04 = "/mobile/needCar/findGoods04.do";

    /**
     * 指定承运
     */
    public static final String ASSIGNED_RUN = "/mobile/needCar/assignedRun.do";

    /**
     * 订单管理-配货记录-已抢单
     */
    public static final String FIND_MY_GOODS_01 = "/mobile/needCar/findMyGoods01.do";

    /**
     * 订单管理-配货记录-待评价
     */
    public static final String FIND_MY_GOODS_02 = "/mobile/needCar/findMyGoods02.do";

    /**
     * 订单管理-配货记录-历史
     */
    public static final String FIND_MY_GOODS_03 = "/mobile/needCar/findMyGoods03.do";

    /**
     * 精准找车
     */
    public static final String FIND_CARS = "/mobile/needCar/findCars.do";

    /**
     * 取消订单
     */
    public static final String CANCEL_ORDER = "/mobile/needCar/cancelOrder.do";

    /**
     * 周边货源
     */
    public static final String FIND_BOUNDS_GOODS = "/mobile/needCar/findBoundsGoods.do";

    /**
     * 周边车辆
     */
    public static final String FIND_BOUNDS_CARS = "/mobile/needCar/findBoundsCars.do";

    /**
     * 再次推送货源
     */
    public static final String AGAIN_PUSH_GOODS = "/mobile/needCar/againPushGoods.do";

    /**
     * 查询当日推送货源(司机端开始接单)
     */
    public static final String FIND_DAY_GOODSPUSH = "/mobile/needCar/findDayGoodspush.do";

    /**
     * 再次发货
     */
    public static final String AGAIN_ADD_GOODS = "/mobile/needCar/againAddGoods.do";

    /**
     * 货源订单待处理或取消订单查询
     */
    public static final String FIND_CANCEL_GOODS_ODERS = "/mobile/needCar/findCalcleOrderList.do";

    /**
     * 订单管理首页查询订单数量 liujq
     */
    public static final String FIND_ORDER_NUM = "/mobile/needCar/findOrderNum.do";

    /**
     * 发货 待评价 更改到货状态 liujq
     */
    public static final String UP_ARRIVAL_GOODS_CONFIRM = "/mobile/needCar/upArrivalGoodsConfirm.do";

    /**
     * 发货 客服处理中查询最新的处理状态 liujq
     */
    public static final String FIND_CUSTOM__REMARK = "/mobile/needCar/findCustomRemark.do";

    /**
     * 查询订单 luzh
     */
    public static final String FIND_MAT_ORDER_LIST_URL = "/mobile/needCar/findGoodsList.do";

    /**
     * 根据订单号查询起点、终点、司机坐标 luzh
     */
    public static final String FIND_MAT_GOODS_COORD_URL = "/mobile/needCar/findMatGoodsCoord.do";

    /**
     * 待确定订单(物流公司app)
     */
    public static final String FIND_GOODS_FOR_LOGISTICS_URL = "/mobile/needCar/findGoodsForLogistics.do";

    /**
     * 指定给自己的货源(物流公司app)
     */
    public static final String FIND_GOODSLIST_FORLOGISTICS_URL = "/mobile/needCar/findGoodsListForLogistics.do";

    /**
     * 填写发货单(物流公司app)
     */
    public static final String ADD_SHIPPER_URL = "/mobile/needCar/addShipperAndPhotos.do";

    /**
     * 修改托运单发货单(物流公司app)
     */
    public static final String UPD_SHIPPER_URL = "/mobile/needCar/modifyShipperAndPhotos.do";

    /**
     * 物流公司我要找货
     */
    public static final String FIND_GOODS_FOR_LOGISTICS_APP = "/mobile/needCar/findGoodsForLogisticsApp.do";

    /**
     * 查看该订单是否已取消
     */
    public static final String FIND_GOODS_IS_CANCLE = "/mobile/needCar/findGoodsIsCancle.do";

    /**
     * 司机停止接单
     */
    public static final String CAR_STATE_STOP = "/mobile/needCar/modifyCarStateStop.do";

    /**
     * 司机取货超时，解锁订单
     */
    public static final String DRIVER_CAN_TAKE_GOODS = "/mobile/needCar/modifyGoodsCanTake.do";

    public static void main(String[] args) {
        // addGoodsParam();
        // findGoodsParam();
        // addRobParam();
        // findHistoryAddr();
        // assignedRunParam();
        // findMyGoodsParam();
        // findCarsParam();
        cancelOrderParam();
        // findBoundsCarsParam();
        // findBoundsGoodsParam();
        // againPushGoodsParam();
        // findDayGoodspushParam();
        // findCalcleOrderList();
    }

    private static void findDayGoodspushParam() {
        FindDayGoodspushRequest req = new FindDayGoodspushRequest(1, "0", "0", "13581924147");
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + FIND_DAY_GOODSPUSH + "?req=" +
        // JacksonUtil.toJson(req));

    }

    private static void againPushGoodsParam() {
        // TODO Auto-generated method stub
        AgainPushGoodsRequest req = new AgainPushGoodsRequest(1, "0", "0", "18621708826");
        req.setGoodsId(420l);
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + AGAIN_PUSH_GOODS + "?req=" +
        // JacksonUtil.toJson(req));
    }

    private static void findBoundsGoodsParam() {
        FindBoundsGoodsRequest req = new FindBoundsGoodsRequest(1, "0", "0", "18621708826");
        req.setAccountId(74);
        BoundsVo boundsVo = new BoundsVo();
        boundsVo.setLng("117.33323");
        boundsVo.setLat("36.5544");
        boundsVo.setSouthWestLng("115.49481");
        boundsVo.setSouthWestLat("38.886565");
        boundsVo.setNorthEastLng("116.728229");
        boundsVo.setNorthEastLat("40.154951");
        req.setBoundsVo(boundsVo);
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + FIND_BOUNDS_GOODS + "?req=" +
        // JacksonUtil.toJson(req));

    }

    // 周边车辆
    private static void findBoundsCarsParam() {
        FindBoundsCarsRequest req = new FindBoundsCarsRequest(1, "0", "0", "18621708826");
        req.setAccountId(74);
        BoundsVo boundsVo = new BoundsVo();
        boundsVo.setLng("117.33323");
        boundsVo.setLat("36.5544");
        boundsVo.setSouthWestLng("115.49481");
        boundsVo.setSouthWestLat("38.886565");
        boundsVo.setNorthEastLng("116.728229");
        boundsVo.setNorthEastLat("40.154951");
        req.setBoundsVo(boundsVo);
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + FIND_BOUNDS_CARS + "?req=" +
        // JacksonUtil.toJson(req));

    }

    // 取消订单
    private static void cancelOrderParam() {
        CancelOrderRequest req = new CancelOrderRequest();
        req.setAppType(AppVersionConstant.TYPE_ANDROID_ENTERPRISE);
        req.setGoodsId(598l);
        req.setAccountId(853);
        req.setState("8");
        req.setCancelReason("货物数量太少我无法运输！我的大货车很大这样导致我赔本做生意。");
        String ipaddr = "http://127.0.0.125:8080/";
        // System.out.println(ipaddr + CANCEL_ORDER + "?req=" +
        // JacksonUtil.toJson(req));
    }

    private static void findCarsParam() {
        FindCarsRequest req = new FindCarsRequest();
        req.setAppType(AppVersionConstant.TYPE_ANDROID_ENTERPRISE);
        req.setLoginToken("0");
        req.setLtywfz("0");
        // req.setLng("116.647823");
        // req.setLat("39.921774");
        req.setUserName("18621708826");
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + FIND_CARS + "?req=" +
        // JacksonUtil.toJson(req));

    }

    private static void findMyGoodsParam() {
        FindMyGoodsRequest req = new FindMyGoodsRequest();
        req.setAppType(AppVersionConstant.TYPE_ANDROID_ENTERPRISE);
        req.setLoginToken("0");
        req.setLtywfz("0");
        req.setUserName("18621708826");
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + FIND_MY_GOODS_01 + "?req=" +
        // JacksonUtil.toJson(req));

    }

    private static void assignedRunParam() {
        AssignedRunRequest req = new AssignedRunRequest();
        req.setAppType(AppVersionConstant.TYPE_ANDROID_ENTERPRISE);
        req.setLoginToken("0");
        req.setLtywfz("0");
        req.setUserName("18621708826");
        req.setDriverId(75);
        req.setGoodsAccountId(70);
        req.setGoodsId(4l);
        req.setOrderNo("2015071474");
        // req.setOrderRobId(4);
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + ASSIGNED_RUN + "?req=" +
        // JacksonUtil.toJson(req));

    }

    private static void findHistoryAddr() {
        FindHistoryAddrRequest req = new FindHistoryAddrRequest();
        req.setAppType(AppVersionConstant.TYPE_ANDROID_ENTERPRISE);
        req.setLoginToken("0");
        req.setLtywfz("0");
        req.setUserName("18621708826");
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + FIND_HISTORY_ADDR + "?req=" +
        // JacksonUtil.toJson(req));

    }

    private static void addRobParam() {
        AddRobRequest req = new AddRobRequest();
        req.setAppType(AppVersionConstant.TYPE_ANDROID_DRIVER);
        req.setLoginToken("0");
        req.setLtywfz("0");
        req.setUserName("18621708826");
        req.setRobAccountId(74);
        req.setGoodsId(18l);
        req.setGoodsNo("20150716318");
        req.setAccountId(75);
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + ADD_ROB + "?req=" +
        // JacksonUtil.toJson(req));
    }

    private static void findGoodsParam() {
        FindGoodsRequest req = new FindGoodsRequest();
        req.setAppType(AppVersionConstant.TYPE_ANDROID_ENTERPRISE);
        req.setCarType("1");
        req.setEndCity("1201");
        req.setEndProvice("12");
        // req.setLat("36.5544");
        // req.setLng("117.33323");
        req.setLoginToken("0");
        req.setLtywfz("0");
        req.setStartCity("1101");
        req.setStartProvice("11");
        req.setUserName("18621708826");
        req.setOrderbyStr(FindGoodsConstant.ORDERBY_1);
        String ipaddr = "http://127.0.0.125:8080/";
        // System.out.println(ipaddr + FIND_GOODS + "?req=" +
        // JacksonUtil.toJson(req));
    }

    private static void addGoodsParam() {

        AddGoodsRequest req = new AddGoodsRequest(1, "1", "1", "18621708826");
        GoodsVo goodsVo = new GoodsVo();
        goodsVo.setAccountId(70);
        goodsVo.setAccount("18612253304");
        goodsVo.setReleaseName("发货信息部");
        goodsVo.setStartAddress("八里桥竹木厂小区11号楼");
        goodsVo.setStartProvice("11");
        goodsVo.setStartCity("1101");
        goodsVo.setStartCounty("110112");
        goodsVo.setEndAddress("围堤道184号");
        goodsVo.setEndCity("1201");
        goodsVo.setEndCounty("120103");
        goodsVo.setEndProvice("12");
        goodsVo.setGoodsLoad(10);
        goodsVo.setGoodsSize(5.5);
        goodsVo.setGoodsSpecies("1");
        goodsVo.setGoodsType("1");// 钢材
        goodsVo.setIsCarload("1");// 是否整车
        goodsVo.setIsMycar("0");
        goodsVo.setNeedCarTime("2015-07-16 11:00:00");
        goodsVo.setNeedCarType("01");
        goodsVo.setNeedCarLength("0101");
        goodsVo.setNeedDesc("货主发干线,北京翠微到天津河西");
        goodsVo.setReleaseTelphone("18621708826");

        req.setGoodsVo(goodsVo);
        String ipaddr = "http://10.0.0.177:8081/";
        // System.out.println(ipaddr + ADD_GOODS + "?req=" +
        // JacksonUtil.toJson(req));

    }

    private static void findCalcleOrderList() {
        CancelOrderRequest req = new CancelOrderRequest();
        req.setAccountId(863);
        req.setState("1");
        String ipaddr = "http://127.0.0.1:8081/";
        // System.out.println(ipaddr + FIND_CANCEL_GOODS_ODERS + "?req=" +
        // JacksonUtil.toJson(req));
    }

}
